Top-down Parsing with Simultaneous Evaluation of Noncircular Attribute Grammars
نویسندگان
چکیده
This paper introduces a machinery called attributed top-down parsing automaton which performs top{down parsing of strings and, simultaneously, the evaluation of arbitrary noncircular attribute grammars. The strategy of the machinery is based on a single depth{ rst left{to{right traversal over the syntax tree. There is no need to traverse parts of the syntax tree more than once, and hence, the syntax tree itself does not have to be maintained. Attribute values are stored in a graph component, and values of attributes which are needed but not yet computed are represented by particular nodes. Values of attributes which refer to such uncomputed attributes are represented by trees over operation symbols in which pointers to the particular nodes at their leaves are maintained. Whenever eventually the needed attribute value is computed, it is glued into the graph at the appropriate nodes.
منابع مشابه
Lazy Combinators for Executable Specifications of General Attribute Grammars
A lazy-evaluation based top-down parsing algorithm has been implemented as a set of higher-order functions (combinators) which support directly-executable specifications of fully general attribute grammars. This approach extends aspects of previous approaches, and allows natural language processors to be constructed as modular and declarative specifications while accommodating ambiguous context...
متن کاملModular Natural Language Processing Using Declarative Attribute Grammars
A system based on a general top-down parsing algorithm has been developed which allows language processors to be created as executable specifications of arbitrary attribute grammars. Declarative notation of attribute grammars allows modular construction of executable language definitions. Syntax is defined through general context-free grammar rules, and meaning is defined by associated semantic...
متن کاملA systematic approach to the implementation of attribute grammars with conventional compiler construction tools
This article describes structure-preserving coding patterns to code arbitrary non-circular attribute grammars as syntax-directed translation schemes for bottom-up and top-down parser generation tools. In these translation schemes, semantic actions are written in terms of a small repertory of primitive attribution operations. By providing alternative implementations for these attribution operati...
متن کاملGuarded Attribute Grammars
Contrary to a widely-held belief, it is possible to construct executable specifications of language processors that use a top-down parsing strategy and which have structures that directly reflect the structure of grammars containing left-recursive productions. A novel technique has been discovered by which the non-termination that would otherwise occur is avoided by ‘guarding’ top-down left-rec...
متن کاملLiteral Movement Grammars
Literal movement grammars (LMGs) provide a general account of extraposition phenomena through an attribute mechanism allowing top-down displacement of syntactical information. LMGs provide a simple and efficient treatment of complex linguistic phenomena such as cross-serial dependencies in German and Dutch—separating the treatment of natural language into a parsing phase closely resembling trad...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
- Fundam. Inform.
دوره 20 شماره
صفحات -
تاریخ انتشار 1994